<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- saved from url=(0027)http://www.chinaidcard.com/ -->
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
    <meta charset="UTF-8">
    <title>学员修改</title>
    <link href="../../layui/css/layui.css" rel="stylesheet">
    <link href="css/layuiAdmin.css" rel="stylesheet">
    <link href="../../static/css/style.css" rel="stylesheet">
    <script src="../../static/js/jquery.min.js"></script>
    <script src="../../static/js/jquery.cookie.js"></script>
    <script src="../../layui/layui.js"></script>
    <script src="../../static/js/base.js"></script>
    <script src="../../static/js/ax.js"></script>
    <script src="../../static/js/avalon.js"></script>
    <script src="js/constant.js"></script>
    <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
    <!--[if lt IE 9]>
    <script src="../../static/js/html5.js"></script>
    <script src="../../static/js/respond.js"></script>
    <![endif]-->
    <style>
    .layui-upload-img{
        overflow: hidden
    }
    </style>

</head>

<body>

    <div class="layui-fluid">
        <div class="layui-card">
            <div class="layui-card-header layui-row hearder_title">
                <h5 class="layui-col-sm7">学员基本信息</h5>
                <div class="layui-col-sm5 xy_btn">
                    <a class="layui-btn layui-btn-primary btn-left">
                        <i class="layui-icon "></i>上一个学员</a>
                    <a class="layui-btn layui-btn-primary btn-left">下一个学员</a>
                </div>
            </div>
            <div class="content-wrap" ms-controller="test">
                <form class="layui-form layui-form-pane" action="">
                    <div class="layui-row add_student layui-form-item ">
                        <div class="layui-col-md10">
                            <div class="">
                                <!----1-->
                                <div class="layui-row">
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">姓名：</label>
                                        <div class="layui-input-block" style="position: relative;">
                                            <input type="text" maxlength="50" lay-verify="required"  ms-duplex="@name" name="Name" class="layui-input">
                                            <input id="Button1"  class="layui-btn add_btn layui-btn-radius" type="button" value="读   卡" onclick="return Button1_onclick()"
                                                style="position: absolute;right:2px;top: 4px; line-height: 30px; height: 30px;"
                                            />
                                            <img src="" style="width: 91px; height: 108px; display: none;" name="pic" />
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">证件类型：</label>
                                        <div class="layui-input-block">
                                            <select name="sfType" id="sfType" ms-duplex="@sfType" lay-verify="required" lay-filter="aihao">
                                                <option value="">请选择</option>

                                            </select>
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">出生日期：</label>
                                        <div class="layui-input-block">
                                            <input type="text" name="Born" readonly ms-duplex="@birthday" class="layui-input">
                                        </div>
                                    </div>


                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">证件号码：</label>
                                        <div class="layui-input-block">
                                            <input type="text" class="layui-input"  ms-duplex="@certificatesNumber" name="CardNo">
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">国籍：</label>
                                        <div class="layui-input-block">
                                            <select name="country" lay-verify="required" ms-duplex="@country" lay-filter="aihao">
                                                <option value="0">中国</option>
                                                <option value="1"></option>
                                            </select>
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">身份证有效期至：</label>
                                        <div class="layui-input-block">
                                            <input type="text" readonly class="layui-input" ms-duplex="@effectedDate" name="EffectedDate" style="width: 44%;display: inline-block; float: left;">
                                            <span style="float: left; width: 2%; line-height: 38px; text-align: center;">&nbsp;~&nbsp;</span>
                                            <input type="text" readonly ms-duplex="@expiredDate" style="width: 44%; display: inline-block; float: right;" class="layui-input"
                                                name="ExpiredDate">
                                        </div>
                                    </div>




                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">性别：</label>
                                        <div class="layui-input-block">
                                            <input type="text" class="layui-input" readonly ms-duplex="@sex" name="Sex">
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <div class="layui-form-item" pane style="margin-bottom: 0;">
                                            <label class="layui-form-label">学习类别：</label>
                                            <div class="layui-input-block">
                                                <input type="radio" name="stu" ms-duplex="@studyType" value="first" title="初次申领">
                                                <input type="radio" name="stu" ms-duplex="@studyType" value="add" title="增驾">
                                            </div>
                                        </div>

                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">手机号码：</label>
                                        <div class="layui-input-block">
                                            <input type="text"  lay-verify="phone" maxlength="11" class="layui-input" ms-duplex="@phone" name="phone">
                                        </div>
                                    </div>


                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">准驾车型：</label>
                                        <div class="layui-input-block">
                                            <select name="carId" id="carId" ms-duplex="@carId" lay-verify="required" lay-filter="aihao">

                                            </select>
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">暂住证编号：</label>
                                        <div class="layui-input-block">
                                            <input type="text" class="layui-input" ms-duplex="@stayAddreeNumber" name="stayAddreeNumber">
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">电子邮箱：</label>
                                        <div class="layui-input-block">
                                            <input type="text" lay-verify="email" class="layui-input" ms-duplex="@email" name="email">
                                        </div>
                                    </div>


                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">所属辖区：</label>
                                        <div class="layui-input-block  ">
                                            <div class="layui-input " style="padding: 0; box-sizing: border-box;     border: 0;">
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="provinceSelect" lay-verify="required" id='driverprovinceId' ms-duplex="@provId_1">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @provlist">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="regionSelect_ae" lay-verify="required" id='drivercityId' ms-duplex="@cityId_1">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @citylist">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="areaSelect"  lay-verify="required"  id='driverareaId' ms-duplex="@areaId_1">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @arealist">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div style="clear: both;"></div>
                                            </div>

                                        </div>
                                    </div>

                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">

                                        <label class="layui-form-label">住所详细地址：</label>
                                        <div class="layui-input-block">
                                            <input type="text" class="layui-input" ms-duplex="@addressDetailed" name="addressDetailed">
                                        </div>
                                    </div>
                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">报名来源：</label>
                                        <div class="layui-input-block">
                                            <input type="text" class="layui-input" ms-duplex="@registeredSource" name="registeredSource">
                                        </div>
                                    </div>


                                    <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                        <label class="layui-form-label">登记住所行政区划：</label>
                                        <div class="layui-input-block">
                                            <div class="layui-input " style="padding: 0; box-sizing: border-box;     border: 0;">
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="provinceSelect_tow" lay-verify="required" id='driverprovinceId_tow' ms-duplex="@provId_2">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @provlist">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="regionSelect_tow" lay-verify="required" id='drivercityId_tow' ms-duplex="@cityId_1">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @citylist_tow">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div class="layui-col-lg4 layui-col-md4 layui-xs4" style="width: 33.33%;float: left;">
                                                    <select lay-filter="areaSelect_tow" lay-verify="required" id='driverareaId_tow' ms-duplex="@areaId_1">
                                                        <option value="">请选择</option>
                                                        <option ms-attr="{value: el.id}" ms-for="($index, el) in @arealist_tow">{{el.name}}</option>
                                                    </select>
                                                </div>
                                                <div class="clear:both"></div>
                                            </div>

                                        </div>
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">登记住所详细地址：</label>
                                    <div class="layui-input-block">
                                            <input type="text" class="layui-input" readonly ms-duplex="@registeredResidence" name="Address">
                                        <!-- <input type="text" class="layui-input" name="registeredResidence" ms-duplex="@registeredResidence"> -->
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <!-- 本地或非本地 -->
                                    <label class="layui-form-label">来源：</label>
                                    <div class="layui-input-block">
                                        <!--  <input type="text" class="layui-input" name="field">-->
                                        <input type="text" class="layui-input" name="studentSource" ms-duplex="@studentSource">
                                    </div>
                                </div>



                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">学费：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" name="registeredTuition" ms-duplex="@registeredTuition">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">学员编号：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" name="studentNumber" ms-duplex="@studentNumber" id="studentNumber">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">报名日期：</label>
                                    <div class="layui-input-block">
                                        <input type="text" readonly class="layui-input" ms-duplex="@registeredTime" value="<%=new SimpleDateFormat('yyyy-MM-dd').format(new Date()) %>"
                                            name="registeredTime" id="registeredTime">
                                    </div>
                                </div>



                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">(驾校)结构名称：</label>
                                    <div class="layui-input-block">
                                        <input type="text" readonly class="layui-input" name="driversId" id="driversId">
                                    </div>
                                </div>

                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">推荐码：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" ms-duplex="@referralCode" name="referralCode">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">民族：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly ms-duplex="@nation" name="Nation">
                                    </div>
                                </div>
                                <!-- <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">地址：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly ms-duplex="@address" name="Address">
                                    </div>
                                </div> -->
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">签发机关：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly readonly ms-duplex="@IssuedAt" name="IssuedAt">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">模块号码：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly ms-duplex="@SAMID" name="SAMID">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">照片编码：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly ms-duplex="@picture" name="Picture">
                                    </div>
                                </div>
                                <div class="layui-col-lg4 layui-col-md6 layui-xs12">
                                    <label class="layui-form-label">编码长度：</label>
                                    <div class="layui-input-block">
                                        <input type="text" class="layui-input" readonly ms-duplex="@PictureLen" name="PictureLen">
                                    </div>
                                </div>
                                <div class="layui-col-xs12">
                                    <label class="layui-form-label" style="height: 120px; line-height: 120px;">备注</label>
                                    <div class="layui-input-block">
                                        <textarea name="reason" ms-duplex="@reason" placeholder="请输入内容" style="height: 120px;" class="layui-textarea" style="min-height: 135px;"></textarea>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="layui-col-md2">
                            <img src="" width="90%;" style="display: block; margin: 0 auto;margin-top:30px;">
                        </div>
                    </div>

                    <div class="layui-form-item">
                        <div class="layui-form-item  layui-row ptfile" pane>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">驾校申请表：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@cxjs" ms-attr="{src:@fileShowUrl +'?id='+@cxjs}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" :click="removeimg('cxjs')" ms-if="@cxjs"></i>
                                            <input type="hidden" name="cxjsId" id="cxjsId" />
                                            <input type="hidden" name="cxjsType" id="cxjsType" value="cxjs" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('cxjs')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">互联网面签协议：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@mqb" ms-attr="{src:@fileShowUrl +'?id='+@mqb}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@mqb" :click="removeimg('mqb')"></i>
                                            <input type="hidden" name="mqbId" id="mqbId" />
                                            <input type="hidden" name="mqbType" id="mqbType" value="mqb" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('mqb')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">

                                <label class="layui-form-label">指纹：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@zw" ms-attr="{src:@fileShowUrl +'?id='+@zw}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@zw" :click="removeimg('zw')"></i>
                                            <input type="hidden" name="zwId" id="zwId" />
                                            <input type="hidden" name="zwType" id="zwType" value="zw" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('zw')">上传图片</a>
                                    </div>
                                </div>

                            </div>
                            <div class="layui-col-md4 layui-col-sm6">

                                <label class="layui-form-label">证件照：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@zjzo" ms-attr="{src:@fileShowUrl +'?id='+@zjzo}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@zjzo" :click="removeimg('zjzo')"></i>
                                            <input type="hidden" name="zjzoId" id="zjzoId" />
                                            <input type="hidden" name="zjzoType" id="zjzoType" value="zjzo" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('zjzo')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">原驾驶证：</label>
                                <div class="layui-input-block">
                                    <!--<input type="text" class="layui-input" name="originalDriverLicense">-->
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@ljz" ms-attr="{src:@fileShowUrl +'?id='+@ljz}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@ljz" :click="removeimg('ljz')"></i>
                                            <input type="hidden" name="cxjsId" id="ljzId" />
                                            <input type="hidden" name="cxjsType" id="ljzType" value="ljz" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('ljz')">上传图片</a>

                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">身份证正面：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@idz" ms-attr="{src:@fileShowUrl +'?id='+@idz}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@idz" :click="removeimg('idz')"></i>
                                            <input type="hidden" name="idzId" id="idzId" />
                                            <input type="hidden" name="idzType" id="idzType" value="idz" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('idz')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">身份证反面：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@idf" ms-attr="{src:@fileShowUrl +'?id='+@idf}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@idf" :click="removeimg('idf')"></i>
                                            <input type="hidden" name="idfId" id="idfId" />
                                            <input type="hidden" name="idfType" id="idfType" value="idf" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('idf')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">提交表图片：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@tjbtp" ms-attr="{src:@fileShowUrl +'?id='+@tjbtp}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@tjbtp" :click="removeimg('tjbtp')"></i>
                                            <input type="hidden" name="tjbtpId" id="tjbtpId" />
                                            <input type="hidden" name="tjbtpType" id="tjbtpType" value="tjbtp" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('tjbtp')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">现场照片：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@scenePhotos" ms-attr="{src:@fileShowUrl +'?id='+@scenePhotos}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@scenePhotos" :click="removeimg('scenePhotos')"></i>
                                            <input type="hidden" name="scenePhotosId" id="scenePhotosId" />
                                            <input type="hidden" name="scenePhotosType" id="scenePhotosType" value="scenePhotos" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('scenePhotos')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">身份证电子照片：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@sfzdzz" ms-attr="{src:@fileShowUrl +'?id='+@sfzdzz}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@sfzdzz" :click="removeimg('sfzdzz')"></i>
                                            <input type="hidden" name="sfzdzzId" id="sfzdzzId" />
                                            <input type="hidden" name="sfzdzzType" id="sfzdzzType" value="sfzdzz" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('sfzdzz')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">注册表面签照：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@zcbmqz" ms-attr="{src:@fileShowUrl +'?id='+@zcbmqz}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@zcbmqz" :click="removeimg('zcbmqz')"></i>
                                            <input type="hidden" name="zcbmqzId" id="zcbmqzId" />
                                            <input type="hidden" name="zcbmqzType" id="zcbmqzType" value="zcbmqz" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('zcbmqz')">上传图片</a>

                                    </div>
                                </div>
                            </div>
                            <div class="layui-col-md4 layui-col-sm6">
                                <label class="layui-form-label">居住证照片：</label>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <div class="layui-upload-list fileItem" style="visibility:inherit;">
                                            <div class="layui-upload-img" style="visibility:inherit;height: 100px;" class="layui-upload-img">
                                                <img id="cxjsSrc" ms-if="@zzpermit" ms-attr="{src:@fileShowUrl +'?id='+@zzpermit}">
                                            </div>
                                            <i class="layui-icon layui-icon-close" ms-if="@zzpermit" :click="removeimg('zzpermit')"></i>
                                            <input type="hidden" name="zzpermitId" id="zzpermitId" />
                                            <input type="hidden" name="zzpermit" value="zzpermit" />
                                        </div>
                                        <a type="button" class="layui-btn layui-btn-primary filebtn" :click="uploadss('zzpermit')">上传图片</a>
                                    </div>
                                </div>
                            </div>
                        </div>


                        <a style="display: none" type="button" class="layui-btn layui-btn-primary filebtn" id="upload">上传图片</a>

                        <div class="layui-input-block">
                            <button class="layui-btn change_btn btn-left" lay-submit lay-filter="submitStudentMy">保存</button>
                            <button class="layui-btn add_btn btn-left" lay-submit lay-filter="submitStudent">立即提交</button>
                            <button type="reset" class="layui-btn layui-btn-primary btn-left">重置</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>


        <div class="margintop layui-card content-wrap">
            <OBJECT classid="clsid:10946843-7507-44FE-ACE8-2B3483D179B7" id="CVR_IDCard" name="CVR_IDCard" width="0" height="0">
            </OBJECT>

            <div style="text-align:center;">
                <object classid="clsid:454C18E2-8B7D-43C6-8C17-B1825B49D7DE" id="captrue" width="400" height="300"></object>
            </div>

            <p>
                <form method="POST" action="--WEBBOT-SELF--" name="form1">
                    <input type="button" value="启动主" name="StartBtn" onclick="Start1_onclick()">
                    <input type="button" value="启动副" name="StopBtn" onclick="Start2_onclick()">
                    <input type="button" value="停止" name="StopBtn" onclick="Stop_onclick()">
                    <input type="button" value="JPG" name="SaveJPGBtn" onclick="SaveJPG_onclick()">

                </form>
            </p>
        </div>
    </div>
    </div>

</body>


<script language="javascript" type="text/javascript">
    $(function () {
            document.all['Name'].value = "陈鸿彬";
            document.all['Sex'].value = "男";
            document.all['Nation'].value = "汉";
            document.all['Born'].value = "2018年08月26日";
            document.all['Address'].value = "重庆市忠县新立镇红岩村二组38号";
            document.all['CardNo'].value = "2476";
            document.all['IssuedAt'].value = "2476";
            document.all['EffectedDate'].value = "2015.12.30";
            document.all['ExpiredDate'].value = "2025.12.30";
            document.all['SAMID'].value = "111";
            document.all['pic'].src = "";
            document.all['Picture'].value = "";
            document.all['PictureLen'].value = "";
   
    });
    function ClearForm() {
        document.all['Name'].value = "";
        document.all['Sex'].value = "";
        document.all['Nation'].value = "";
        document.all['Born'].value = "";
        document.all['Address'].value = "";
        document.all['CardNo'].value = "";
        document.all['IssuedAt'].value = "";
        document.all['EffectedDate'].value = "";
        document.all['ExpiredDate'].value = "";
        document.all['SAMID'].value = "";
        document.all['pic'].src = "";
        document.all['Picture'].value = "";
        document.all['PictureLen'].value = "";
        return true;
    }
    function Button1_onclick() {
        var CVR_IDCard = document.getElementById("CVR_IDCard");
        var strReadResult = CVR_IDCard.ReadCard();
        if (strReadResult == "0") {
            ClearForm();
            document.all['Name'].value = CVR_IDCard.Name;
            document.all['Sex'].value = CVR_IDCard.Sex;
            document.all['Nation'].value = CVR_IDCard.Nation;
            document.all['Born'].value = CVR_IDCard.Born;
            document.all['Address'].value = CVR_IDCard.Address;
            document.all['CardNo'].value = CVR_IDCard.CardNo;
            document.all['IssuedAt'].value = CVR_IDCard.IssuedAt;
            document.all['EffectedDate'].value = CVR_IDCard.EffectedDate;
            document.all['ExpiredDate'].value = CVR_IDCard.ExpiredDate;
            document.all['SAMID'].value = CVR_IDCard.SAMID;
            document.all['pic'].src = CVR_IDCard.Pic;
            document.all['Picture'].value = CVR_IDCard.Picture;
            document.all['PictureLen'].value = CVR_IDCard.PictureLen
        }
        else {
            ClearForm();
            alert(strReadResult);
        }

    }


    function Button3_onclick() {
        var CVR_IDCard = document.getElementById("CVR_IDCard");
        CVR_IDCard.AboutBox();

    }
    function Start1_onclick() {
        var str = captrue.bStopPlay();
        var str = captrue.bStartPlay();
    }
    function Start2_onclick() {
        var str = captrue.bStopPlay();
        var str = captrue.bStartPlay2(0);
    }

    function Stop_onclick() {
        var str = captrue.bStopPlay();
    }

    function SaveJPG_onclick() {
        var str = captrue.bSaveJPG("D:\\", "JPG");
    }
</script>


<script>

    var vm = avalon.define({
        $id: "test",
        name: '',//姓名
        sex: '',//性别
        nation: '',//民族
        birthday: '',//出生日期：
        certificatesNumber: '',//证件号码
        issuedAt: '',//签发机关
        effectedDate: '',//身份证有效期 开始
        expiredDate: '',//身份证有效期 结束
        picture: '',//图片编码
        sfType: '',//证件类型
        country: '',//国籍
        studyType: 'first',//学习类别
        phone: '',//手机号码
        carId: '',//准驾车型
        stayAddreeNumber: '',//暂住证编号：
        email: '',//电子邮箱
        registeredAreaId: '',//所属辖区
        addressDetailed: '',//住所详细地址：
        registeredSource: '',//报名来源
        registeredRegionId: '',//登记住所行政区划：
        registeredResidence: '',//登记住所详细地址：
        studentSource: 'local',//来源  local  本地     field 外地 
        registeredTuition: '',//学费
        studentNumber: '',//学员编号
        registeredTime: '',//报名日期
        //  driversId : document.all['driversId'].value,//(驾校)结构名称  后台获取
        referralCode: '',//(推荐码
        reason: '',//(备注
        myState: '', //提交给谁
        SAMID: '',//模块号码：
        PictureLen: '',//编码长度
        sfz: '',//身份证头像
        mqb: '',//互联网面签协议
        cxjs: '',//初学驾驶申请表
        zjjs: '',//增驾驾驶申请表
        zw: '',//指纹
        ljz: '',//原驾驶证
        zzz: '',//制证照
        pxjl: '',//培训记录
        xszm: '',//学时证明
        zzpermit: '',//居住证照片
        idz: '',//身份证正面
        idf: '',//身份证反面
        healthForm: '',//体检表
        scenePhotos: '',//现场照片
        zjzo: '',//证件照
        tjbtp: '',//提交表图片
        sfzdzz: '',//身份证电子照片
        zcbmqz: '',//册表面签照
        provId_1: '',
        cityId_1: '',
        areaId_1: '',
        provId_2: '',
        cityId_2: '',
        areaId_2: '',
        provlist: [],
        citylist: [],
        arealist: [],
        infolist: [],
        citylist_tow: [],
        arealist_tow: [],
        pro_city_are: {},
        type: '',
        studentId:"",
        fileShowUrl: fileShowUrl,
        getRegionTree: function () {
            $.ajax({
                url: '../../static/js/addreess.text',  //文件地址
                type: 'GET',     //数据传递方式
                async: false,
                success: function (data) {  //获取数据成功执行的函数
                    var data = JSON.parse(data);
                    var city = data.city;
                    var area = data.area;
                    vm.provlist = data.prove;
                    vm.pro_city_are = data;
                    for (var i in city) {
                        if (city[i].parentId == data.prove[0].id) {
                            vm.citylist.push(city[i])
                            vm.citylist_tow.push(city[i])
                        }
                    }
                    for (var i in area) {
                        if (area[i].parentId == data.city[0].id) {
                            vm.arealist.push(area[i])
                            vm.arealist_tow.push(area[i])
                        }
                    }
                }
            })
        },
        uploadss: function (type) {
            console.log(type)
            vm.type = type;
            $('#upload').click()
        },
        removeimg:function(type){
            vm.type=type;
            if (vm.type == 'cxjs') {
                    vm.cxjs = ''
                }
                if (vm.type == 'mqb') {
                    vm.mqb = ''
                }
                if (vm.type == 'zw') {
                    vm.zw =''
                }
                if (vm.type == 'zjzo') {
                    vm.zjzo =''
                }
                if (vm.type == 'ljz') {
                    vm.ljz = ''
                }
                if (vm.type == 'idz') {
                    vm.idz =''
                }
                if (vm.type == 'idf') {
                    vm.idf = ''
                }
                if (vm.type == 'tjbtp') {
                    vm.tjbtp = ''
                }
                if (vm.type == 'scenePhotos') {
                    vm.scenePhotos = ''
                }
                if (vm.type == 'sfzdzz') {
                    vm.sfzdzz = ''
                }
                if (vm.type == 'zcbmqz') {
                    vm.zcbmqz = ''
                }
                if (vm.type == 'zzpermit') {
                    vm.zzpermit =''
                }

        },
        getStudentinfo:function(){
            var studentId=getQueryString("id");
            vm.studentId=studentId;
            var data={
                studentId:studentId
             }
            ax.get({
                url: schoolWebUrl+"/api/student/getStudentById",
                data: data,
                success: function (data) {
                     console.log(data);
                     var data =data.data
                     
        vm.name=data.name         //姓名
        vm.sex=data.sex//性别
        vm.nation=data.nation  //民族
        vm.birthday=data.birthday  //出生日期：
        vm.certificatesNumber=data.certificatesNumber  //证件号码
        vm.issuedAt=data.issuedAt  //签发机关
        vm.effectedDate=data.effectedDate  //身份证有效期 开始
        vm.expiredDate=data.expiredDate  //身份证有效期 结束
        vm.picture=data.picture   //图片编码
        vm.sfType=data.sfType   //证件类型
        vm.country=data.country   //国籍
        vm.studyType=data.studyType   //学习类别
        vm.phone=data.phone   //手机号码
        vm.carId=data.carId  //准驾车型
        vm.stayAddreeNumber=data.stayAddreeNumber   //暂住证编号：
        vm.email=data.email   //电子邮箱
        vm.registeredAreaId=data.registeredAreaId   //所属辖区
        vm.addressDetailed=data.addressDetailed   //住所详细地址：
        vm.registeredSource=data.registeredSource   //报名来源
        vm.registeredRegionId=data.registeredRegionId  //登记住所行政区划：
        vm.registeredResidence=data.registeredResidence   //登记住所详细地址：
        vm.studentSource=data.studentSource  //来源  local  本地     field 外地 
        vm.registeredTuition=data.registeredTuition   //来源：：
        vm.studentNumber=data.studentNumber   //学员编号
        vm.registeredTime=data.registeredTime   //报名日期
        //  driversId : document.all['driversId'].value,//(驾校)结构名称  后台获取
        vm.referralCode=data.referralCode  //(推荐码
        vm.reason=data.reason   //(备注
        vm.myState=data.myState   //提交给谁
        vm.SAMID=data.SAMID   //模块号码：
        vm.PictureLen=data.PictureLen   //编码长度
        vm.sfz=data.sfz   //身份证头像
        vm.mqb=data.mqb   //互联网面签协议
        vm.cxjs=data.cxjs   //初学驾驶申请表
        vm.zjjs=data.zjjs   //增驾驾驶申请表
        vm.zw=data.zw   //指纹
        vm.ljz=data.ljz   //原驾驶证
        vm.zzz=data.zzz  //制证照
        vm.pxjl=data.pxjl   //培训记录
        vm.xszm=data.xszm   //学时证明
        vm.zzpermit=data.zzpermit    //居住证照片
        vm.idz=data.idz   //身份证正面
        vm.idf=data.idf    //身份证反面
        vm.healthForm=data.healthForm    //体检表
        vm.scenePhotos=data.scenePhotos    //现场照片
        vm.zjzo=data.zjzo  //证件照
        vm.tjbtp=data.tjbtp  //提交表图片
        vm.sfzdzz=data.sfzdzz   //身份证电子照片
        vm.zcbmqz=data.zcbmqz   //册表面签照
        vm.provId_1=data.provId_1   
        vm.cityId_1=data.cityId_1    
        vm.areaId_1=data.areaId_1    
        vm.provId_2=data.provId_2   
        vm.areaId_2=data.areaId_2   
        vm.cityId_2=data.cityId_2   
                }
            });
        }
         
    })

    vm.$watch('onReady', function () {
        //获取省市区
        console.log(11)
        vm.getRegionTree();
        vm.getStudentinfo();

    })
    //图片上传



    var table;
    var layer;
    var baseData = null;
    var form;
    var zpType;
    var upload;

    layui.use(['form', 'laydate', 'layer', 'upload'], function () {
        table = layui.table;
        layer = layui.layer;
        form = layui.form,
            upload = layui.upload,
            laydate = layui.laydate;

        //获取当前时间
        var d = new Date();
        var timenow = d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate();
        document.getElementById('registeredTime').value = timenow;
        //省改变
        form.on('select(provinceSelect)', function (data) {
            console.log(data)
            var provinceid = data.value;
          
            vm.citylist.clear();
            vm.arealist.clear();
            for (var i in vm.pro_city_are.city) {
                if (provinceid == vm.pro_city_are.city[i].parentId) {
                    vm.citylist.push(vm.pro_city_are.city[i])
                }
            }
            var cityid = vm.citylist[0].id;
            for (var i in vm.pro_city_are.area) {
                if (cityid == vm.pro_city_are.area[i].parentId) {
                    vm.arealist.push(vm.pro_city_are.area[i])
                }
            }
            form.render('select');
            vm.provId_1 = data.value;
        });
        // 市改变
        form.on('select(regionSelect_ae)', function (data) {
            var cityid = data.value;
            return false;
            vm.arealist.clear();
            for (var i in vm.pro_city_are.area) {
                if (cityid == vm.pro_city_are.area[i].parentId) {
                    vm.arealist.push(vm.pro_city_are.area[i])
                }
            }
            form.render('select');
            vm.cityId_1 = data.value;

        });
        // 区改变
        form.on('select(areaSelect)', function (data) {
            vm.areaId_1 = data.value;

        });
        // 省改变
        form.on('select(provinceSelect_tow)', function (data) {
            console.log(data)
            vm.citylist_tow.clear();
     
            var provinceid = data.value
           
            for (var i in vm.pro_city_are.city) {
                if (provinceid == vm.pro_city_are.city[i].parentId) {
                    vm.citylist_tow.push(vm.pro_city_are.city[i])
                }
            }
            vm.arealist_tow.clear();
            vm.provId_2 = data.value;
            form.render('select');
           
        });
        // 市改变
        form.on('select(regionSelect_tow)', function (data) {
            var cityid = data.value;
            vm.arealist_tow.clear();
            for (var i in vm.pro_city_are.area) {
                if (cityid == vm.pro_city_are.area[i].parentId) {
                    vm.arealist_tow.push(vm.pro_city_are.area[i])
                }
            }
            form.render('select');
            vm.cityId_2 = data.value;
        });
        // 区改变
        form.on('select(areaSelect_tow)', function (data) {

            vm.areaId_2 = data.value;

        });
        //总校立即提交
        form.on('submit(submitStudent)', function (data) {
            console.log(1)
            getsubimit(0)
            return false
        });
        //提交数据
        function getsubimit(type){
        var myState=  type 
        var data = {
                id:vm.studentId,//需要修改的id
                name: vm.name,//姓名
                sex: vm.sex,//性别
                nation: vm.nation,//民族
                birthday: vm.birthday,//出生日期：
                certificatesNumber: vm.certificatesNumber,//证件号码
                issuedAt: vm.issuedAt,//签发机关
                effectedDate: vm.effectedDate,//身份证有效期 开始
                expiredDate: vm.expiredDate,//身份证有效期 结束
                picture: vm.picture,//图片编码
                country: vm.country,//证件类型
                country: vm.country,//国籍
                studyType: vm.studyType,//学习类别
                phone: vm.phone,//手机号码
                carId: vm.carId,//准驾车型
                stayAddreeNumber: vm.stayAddreeNumber,//暂住证编号：
                email: vm.email,//电子邮箱
                registeredAreaId: vm.registeredAreaId,//所属辖区
                addressDetailed: vm.addressDetailed,//住所详细地址：
                registeredSource: vm.registeredSource,//报名来源
                registeredRegionId: vm.registeredRegionId,//登记住所行政区划：
                registeredResidence: vm.registeredResidence,//登记住所详细地址：
                studentSource: vm.studentSource,//来源
                registeredTuition: vm.registeredTuition,//学费：
                studentNumber: vm.studentNumber,//学员编号
                registeredTime: vm.registeredTime,//报名日期
                //  driversId : document.all['driversId'].value,//(驾校)结构名称  后台获取
                referralCode: vm.referralCode,//(推荐码
                reason: vm.reason,//(备注
                myState: myState, //提交给谁
                SAMID: vm.SAMID,//模块号码：
                PictureLen: vm.PictureLen,//编码长度
                sfz: vm.sfz,//身份证头像
                mqb: vm.mqb,//互联网面签协议
                cxjs: vm.cxjs,//初学驾驶申请表
                zjjs: vm.zjjs,//增驾驾驶申请表
                zw: vm.zw,//指纹
                ljz: vm.ljz,//原驾驶证
                zzz: vm.zzz,//制证照
                pxjl: vm.pxjl,//培训记录
                xszm: vm.xszm,//学时证明
                zzpermit: vm.zzpermit,//居住证照片
                idz: vm.idz,//身份证正面
                idf: vm.idf,//身份证反面
                healthForm: vm.healthForm,//体检表
                scenePhotos: vm.scenePhotos,//现场照片
                zjzo: vm.zjzo,//证件照
                tjbtp: vm.tjbtp,//提交表图片
                sfzdzz: vm.sfzdzz,//身份证电子照片
                zcbmqz: vm.zcbmqz,//册表面签照
                provId_1: vm.provId_1,
                cityId_1: vm.cityId_1,
                areaId_1: vm.areaId_1,
                provId_2: vm.provId_2,
                cityId_2: vm.cityId_2,
                areaId_2: vm.areaId_2,
            }
         console.log(data)
         ax.post({
                url: schoolWebUrl+"/api/student/update",
                data: data,
                
                success: function (data) {
                    layer.msg(data.message);
                    if (data.code == 0) {
                        //刷新父页面
                        parent.location.reload();
                        layer.closeAll("iframe");
                    } else {

                    }
                }
            });
            return false;
      }
       
       //保存
        form.on('submit(submitStudentMy)', function () {
            getsubimit(1)
          
        });
        //图片上传 简便方法
        var addCoachLicense = upload.render({

            elem: '#upload',
            url: fileUploadUrl + "?appId=" + appId + "&userId=" + userId + "&type=" + type,
            before: function (obj) {
                //预读本地文件示例，不支持ie8
                /*obj.preview(function(index, file, result){
                    $('#demo1').attr('src', result); //图片链接（base64）
                });*/
            },
            done: function (res) {
                //上传成功
                if (vm.type == 'cxjs') {
                    vm.cxjs = res.data
                }
                if (vm.type == 'mqb') {
                    vm.mqb = res.data
                }
                if (vm.type == 'zw') {
                    vm.zw = res.data
                }
                if (vm.type == 'zjzo') {
                    vm.zjzo = res.data
                }
                if (vm.type == 'ljz') {
                    vm.ljz = res.data
                }
                if (vm.type == 'idz') {
                    vm.idz = res.data
                }
                if (vm.type == 'idf') {
                    vm.idf = res.data
                }
                if (vm.type == 'tjbtp') {
                    vm.tjbtp = res.data
                }
                if (vm.type == 'scenePhotos') {
                    vm.scenePhotos = res.data
                }
                if (vm.type == 'sfzdzz') {
                    vm.sfzdzz = res.data
                }
                if (vm.type == 'zcbmqz') {
                    vm.zcbmqz = res.data
                }
                if (vm.type == 'zzpermit') {
                    vm.zzpermit = res.data
                }
            }
        });

        var initBaseData = function () {
            ax.get({
                url: schoolWebUrl+"/api/student/getBaseData",
                
                success: function (res) {
                    if (res.code == 0) {
                        baseData = res.data;
                        loadBaseData();
                    } else {
                        layer.msg(res.message);
                    }
                }

            });
        };
        var loadBaseData = function () {

            $("#driversId").val(baseData.driverName);
            $("#studentNumber").val(baseData.studentNumber);
            // 初始  证件
            $("#sfType").empty();
            $("#sfType").append("<option value=''>请选择</option>");
            $.each(baseData.zjTypeList, function (index, zj) {
                $("#sfType").append("<option value='" + zj.id + "'>" + zj.code + "</option>");
            });

            // 准驾车型列表
            $("#carId").empty();
            $("#carId").append("<option value=''>请选择</option>");
            $.each(baseData.carTypeList, function (index, carType) {
                $("#carId").append("<option value='" + carType.id + "'>" + carType.code + "</option>");
            });

            // 所属辖区
            $("#registeredAreaId").empty();
            $("#registeredAreaId").append("<option value=''>请选择</option>");
            $.each(baseData.quyuAddressList, function (index, address) {
                $("#registeredAreaId").append("<option value='" + address.id + "'>" + address.code + "</option>");
            });

            //登记住所行政区划
            $("#registeredRegionId").empty();
            $("#registeredRegionId").append("<option value=''>请选择</option>");
            $.each(baseData.xzAddressTimeList, function (index, address) {
                $("#registeredRegionId").append("<option value='" + address.id + "'>" + address.code + "</option>");
            });

            form.render('select');
            baseDataDone = true;

        };
        initBaseData();
        ///////////////////////

    });


    function saveBean(state) {
        var data = {
            name: document.all['Name'].value,//姓名
            sex: document.all['Sex'].value,//性别
            nation: document.all['Nation'].value,//民族
            birthday: document.all['Born'].value,//出生日期：
            address: document.all['Address'].value,//地址  身份证上的地址
            certificatesNumber: document.all['CardNo'].value,//证件号码
            issuedAt: document.all['IssuedAt'].value,//签发机关
            effectedDate: document.all['EffectedDate'].value,//身份证有效期 开始
            expiredDate: document.all['ExpiredDate'].value,//身份证有效期 结束
            picture: "data:image/png;base64," + document.all['Picture'].value,//图片编码
            sfType: document.all['sfType'].value,//证件类型
            country: document.all['country'].value,//国籍
            studyType: $("input[name='stu']:checked").val(),//学习类别
            phone: document.all['phone'].value,//手机号码
            carId: document.all['carId'].value,//准驾车型
            stayAddreeNumber: document.all['stayAddreeNumber'].value,//暂住证编号：
            email: document.all['email'].value,//电子邮箱
            registeredAreaId: document.all['registeredAreaId'].value,//所属辖区
            addressDetailed: document.all['addressDetailed'].value,//住所详细地址：
            registeredSource: document.all['registeredSource'].value,//报名来源
            registeredRegionId: document.all['registeredRegionId'].value,//登记住所行政区划：
            registeredResidence: document.all['registeredResidence'].value,//登记住所详细地址：
            studentSource: document.all['studentSource'].value,//来源
            registeredTuition: document.all['registeredTuition'].value,//学费：
            studentNumber: document.all['studentNumber'].value,//学员编号
            registeredTime: document.all['registeredTime'].value,//报名日期
            //  driversId : document.all['driversId'].value,//(驾校)结构名称  后台获取
            referralCode: document.all['referralCode'].value,//(推荐码
            reason: document.all['reason'].value,//(备注
            myState: state //提交给谁
        }
        return data;
    }


    function listStudent() {
        window.location.href = 'studentList.html';
    }


    function yanz(data) {
        var checkResult = true;
        if (nullOrUndefined(data.name.length)) {
            layer.msg("姓名不能为空");
            checkResult = false;
        }
        if (nullOrUndefined(data.sex)) {
            layer.msg("性别不能为空");
            return false;
        }
        if (nullOrUndefined(data.nation)) {
            layer.msg("民族不能为空");
            return false;
        }
        if (nullOrUndefined(data.birthday)) {
            layer.msg("出生日期不能为空");
            return false;
        }

        if (nullOrUndefined(data.address)) {
            layer.msg("身份证上的地址不能为空");
            return false;
        }
        if (nullOrUndefined(data.certificatesNumber)) {
            layer.msg("证件号码不能为空");
            return false;
        }
        if (nullOrUndefined(data.issuedAt)) {
            layer.msg("签发机关不能为空");
            return false;
        }
        if (nullOrUndefined(data.effectedDate)) {
            layer.msg("身份证有效期不能为空");
            return false;
        }
        if (nullOrUndefined(data.expiredDate)) {
            layer.msg("身份证有效期不能为空");
            return false;
        }
        if (nullOrUndefined(data.sfType)) {
            layer.msg("证件类型不能为空");
            return false;
        }
        if (nullOrUndefined(data.country)) {
            layer.msg("国籍不能为空");
            return false;
        }
        if (nullOrUndefined(data.studyType)) {

            layer.msg("学习类别不能为空!");
            return false;
        }
        if (nullOrUndefined(data.phone)) {
            layer.msg("手机号码不能为空");
            return false;
        }
        if (!(/^1[3|4|5|8][0-9]\d{4,8}$/.test(data.phone))) {
            layer.msg("手机号码格式不对");
            return false;
        }

        if (nullOrUndefined(data.carId)) {
            layer.msg("准驾车型不能为空");
            return false;
        }
        if (nullOrUndefined(data.email)) {
            layer.msg("电子邮箱不能为空");
            return false;
        }
        var regex = /^([0-9A-Za-z\-_\.]+)@([0-9a-z]+\.[a-z]{2,3}(\.[a-z]{2})?)$/g;
        if (!regex.test(data.email)) {
            layer.msg("您输入的电子邮件地址不合法");
            return false;
        }
        //TODO 后面的在加

        return checkResult;
    }

    function nullOrUndefined(data) {

        if (data == "" || data == undefined || data == null) {
            return true;
        }
        return false;
    }
</script>

</html>